package com.myproject.threadlocal;

public class Teat2 {

    public static void main(String[] args) {

        Runnable runnable = new Runnable() {
            @Override
            public void run() {

                ThreadLocal t1 = new ThreadLocal();
                ThreadLocal t2 = new ThreadLocal();
                t1.set("hello");

                System.out.println(t1.get());
                System.out.println(t2.get());

                t1.remove();
            }
        };

        new Thread(runnable).start();

    }

}
